﻿using System;
using System.Composition;
using System.Composition.Hosting;


namespace MEF2Test.ConsoleTest
{
	class Program
	{
		static void Main(string[] args)
		{
			var modelView = new ModelView();
			
			var config = new ContainerConfiguration()
				.WithAssemblies(AddInsCatalog.GetAssembies());
				
			var container = config.CreateContainer();

			// 极其重要的Export与Import块的导入连接。
			container.SatisfyImports(modelView);

			modelView.RunAllEntries();

		}
	}
}
